package com.rui.admin.mapper;


import com.rui.common.pojo.Delivery;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Repository;

import java.util.List;


/**
 * @author huang Zeming
 * @date 2024/06/08
 */
@Component
public interface DeliveryMapper {

    //骑手注册
    int riderRegister(Delivery delivery);

    /*根据oid获取taker*/
    Delivery findTakerByOid(Integer oid);

    /*根据phone查询rider*/
    Delivery findDeliveryByPhone(String phone);


    /*获取骑手总数*/
    Integer getRidersCount();

    /*分页获取骑手信息*/
    List<Delivery> findAllRidersByPage();

    /*根据did查找骑手信息*/
    Delivery findDeliveryByDid(Integer did);

    /*根据oid获取did，增加骑手接单量*/
    Integer addTotalNum(String oid);

}
